package com.opeartion.pojo;

import javax.persistence.Id;
import javax.persistence.Table;
import java.sql.*;

@Table(name = "goods")
public class Goods {
	@Id
	private Integer id;
	private String sn;
	private String name;
	private Integer price;
	private Integer num;
	private Integer alert_num;
	private Integer cost_price;
	private Integer original_price;
	private String image;
	private Integer weight;
	private Timestamp create_time;
	private Timestamp update_time;
	private Integer spu_id;
	private Integer category_id;
	private String category_name;
	private Integer store_id;
	private String store_name;
	private Integer sale_num;
	private Integer comment_num;
	private String status;
	private Integer version;
	private Integer activeId;
	//查看当前商家
	private Store store;
	//查看当前类别
	private Category category;
	//获取参加的活动
	private Activity activity;

	//count_money 获取当前总营业额
	private int  count_money;


	public int getCount_money() {
		return count_money;
	}

	public void setCount_money(int count_money) {
		this.count_money = count_money;
	}

	public Store getStore() {
		return store;
	}

	public void setStore(Store store) {
		this.store = store;
	}

	public Category getCategory() {
		return category;
	}

	public void setCategory(Category category) {
		this.category = category;
	}

	public Activity getActivity() {
		return activity;
	}

	public void setActivity(Activity activity) {
		this.activity = activity;
	}

	public Integer getId(){
		return id;
	}
	public void setId(Integer id){
		this.id=id;
	}
	public String getSn(){
		return sn;
	}
	public void setSn(String sn){
		this.sn=sn;
	}
	public String getName(){
		return name;
	}
	public void setName(String name){
		this.name=name;
	}
	public Integer getPrice(){
		return price;
	}
	public void setPrice(Integer price){
		this.price=price;
	}
	public Integer getNum(){
		return num;
	}
	public void setNum(Integer num){
		this.num=num;
	}
	public Integer getAlert_num(){
		return alert_num;
	}
	public void setAlert_num(Integer alert_num){
		this.alert_num=alert_num;
	}
	public Integer getCost_price(){
		return cost_price;
	}
	public void setCost_price(Integer cost_price){
		this.cost_price=cost_price;
	}
	public Integer getOriginal_price(){
		return original_price;
	}
	public void setOriginal_price(Integer original_price){
		this.original_price=original_price;
	}
	public String getImage(){
		return image;
	}
	public void setImage(String image){
		this.image=image;
	}
	public Integer getWeight(){
		return weight;
	}
	public void setWeight(Integer weight){
		this.weight=weight;
	}
	public Timestamp getCreate_time(){
		return create_time;
	}
	public void setCreate_time(Timestamp create_time){
		this.create_time=create_time;
	}
	public Timestamp getUpdate_time(){
		return update_time;
	}
	public void setUpdate_time(Timestamp update_time){
		this.update_time=update_time;
	}
	public Integer getSpu_id(){
		return spu_id;
	}
	public void setSpu_id(Integer spu_id){
		this.spu_id=spu_id;
	}
	public Integer getCategory_id(){
		return category_id;
	}
	public void setCategory_id(Integer category_id){
		this.category_id=category_id;
	}
	public String getCategory_name(){
		return category_name;
	}
	public void setCategory_name(String category_name){
		this.category_name=category_name;
	}
	public Integer getStore_id(){
		return store_id;
	}
	public void setStore_id(Integer store_id){
		this.store_id=store_id;
	}
	public String getStore_name(){
		return store_name;
	}
	public void setStore_name(String store_name){
		this.store_name=store_name;
	}
	public Integer getSale_num(){
		return sale_num;
	}
	public void setSale_num(Integer sale_num){
		this.sale_num=sale_num;
	}
	public Integer getComment_num(){
		return comment_num;
	}
	public void setComment_num(Integer comment_num){
		this.comment_num=comment_num;
	}
	public String getStatus(){
		return status;
	}
	public void setStatus(String status){
		this.status=status;
	}
	public Integer getVersion(){
		return version;
	}
	public void setVersion(Integer version){
		this.version=version;
	}
	public Integer getActiveId(){
		return activeId;
	}
	public void setActiveId(Integer activeId){
		this.activeId=activeId;
	}

	@Override
	public String toString() {
		return "Goods{" +
				"id=" + id +
				", sn='" + sn + '\'' +
				", name='" + name + '\'' +
				", price=" + price +
				", num=" + num +
				", alert_num=" + alert_num +
				", cost_price=" + cost_price +
				", original_price=" + original_price +
				", image='" + image + '\'' +
				", weight=" + weight +
				", create_time=" + create_time +
				", update_time=" + update_time +
				", spu_id=" + spu_id +
				", category_id=" + category_id +
				", category_name='" + category_name + '\'' +
				", store_id=" + store_id +
				", store_name='" + store_name + '\'' +
				", sale_num=" + sale_num +
				", comment_num=" + comment_num +
				", status='" + status + '\'' +
				", version=" + version +
				", activeId=" + activeId +
				", store=" + store +
				", category=" + category +
				", activity=" + activity +
				", count_money=" + count_money +
				'}';
	}
}

